<?php

namespace App\Models;

use App\Models\System\CheckItem;
use App\Models\System\CheckItemParameter;
use Dcat\Admin\Traits\HasDateTimeFormatter;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
use Illuminate\Database\Eloquent\SoftDeletes;
use Illuminate\Database\Eloquent\Model;

class OrderSampleParameter extends Model
{
	use HasDateTimeFormatter;
    use SoftDeletes;

    protected $table = 'order_sample_parameters';

    protected $guarded = [];

    public function item() : BelongsTo
    {
        return $this->belongsTo(CheckItem::class, 'item_id');
    }

    public function parameter() : BelongsTo
    {
        return $this->belongsTo(CheckItemParameter::class, 'parameter_id');
    }
}
